import request from "../../http";

const articleApi = {
  async getArticleData(query) {
    return request({
      url: "/pc/article/list",
      method: "get",
      params: query
    });
  },
  async getArticleDetail(query) {
    return request({
      url: `/pc/article/${query.id}`,
      method: "get",
      params: query
    });
  },
  // 文章详情精选服务换一换
  async changeServer(id) {
    return request({
      url: `/pc/article/random/${id}`,
      method: "get"
    });
  },
  // 获取收藏资讯
  async getCollectActicle(query) {
    return request({
      url: "/pc/article/link/list",
      method:'get',
      params:query
    });
  }
};

export default articleApi;
